<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="/WEB-INF/views/share/taglib.jsp" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<HEAD>
<TITLE>JTROOM管理系统 | Sign In</TITLE>
<%@ include file="/WEB-INF/views/share/meta.jsp"%>
<META content="text/html; charset=UTF-8" http-equiv=Content-Type>
<META content=blendTrans(Duration=0.5) http-equiv=page-Enter>
<META content=blendTrans(Duration=0.5) http-equiv=page-Exit>
<SCRIPT language=JavaScript>
<!--
function changeImage(obj) {
	obj.src = "${base }/servlet/CheckCodeServlet?" + new Date().getTime();
}
$(document).ready(function(){
	//验证表单
	$("#form").validate({
		rules : {
			username : "required",
			password : "required",
			validateCode : "required",
			validateCode:{
				required:true,
				remote:{
					url: "${base }/checkCode",
		       	    type: 'POST',
		       	 	async:false,
		       	    dataType: 'json'
				}
			}
		}
	});
});
//-->
</SCRIPT>
</HEAD>
<body id="login">
		
		<div id="login-wrapper" class="png_bg">
			<div id="login-top">
				<a href=""><img id="logo" src="${base }/static/images/logo.png" alt="Simpla Admin logo" /></a>
			</div>
			
			<div id="login-content">
				<form action="${base }/login" id="form">
					<div style="margin: 0 auto;text-align: center;margin-bottom: 10px;color: #EA5200;">${message }</div>
					<table cellpadding="0" cellspacing="0" border="0" style="margin: 0 auto;">
						<tr>
							<td valign="center">用户名：</td>
							<td valign="center" style="position: absolute;"><input class="text-input" type="text" style="float: left;width: 209px;" name="username" id="username"/></td>
						</tr>
						<tr style="height: 50px;">
							<td valign="center">密&nbsp;&nbsp;&nbsp;码：</td>
							<td valign="center"><input class="text-input" type="password" style="float: left;width: 209px;" name="password" id="password"/></td>
						</tr>
						<tr>
							<td valign="center">验证码：</td>
							<td valign="center"><input class="text-input" name="validateCode" id="validateCode" type="text" style="width: 100px;float: left;"/><a href="#" style="border: 0px;" alt="点击刷新验证码" ><img alt="点击刷新验证码" src="${base }/servlet/CheckCodeServlet" style="margin-left: 5px;border: 0px;" onclick="changeImage(this)"/></a></td>
						</tr>
						<tr style="height: 50px;">
							<td colspan="2" align="center">
								<input class="button" type="submit" value="Sign In"/>
							</td>
						</tr>
					</table>
					<div class="clear"></div>
				</form>
			</div>
		</div>
  </body>

</html>